home *** CD-ROM | disk | FTP | other *** search
- Path: navajo.gate.net!panther
- From: Josef Faulkner <panther@gate.net>
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: printf in arexx
- Date: Mon, 29 Jan 1996 10:39:40 -0500
- Organization: CyberGate, Inc.
- Message-ID: <Pine.A32.3.91.960129103149.39276A-100000@navajo.gate.net>
- NNTP-Posting-Host: navajo.gate.net
- Mime-Version: 1.0
- Content-Type: TEXT/PLAIN; charset=US-ASCII
-
-
- Roland Bengtsson (roland.bengtsson@mbox3.swipnet.se) wrote:
- : I wanted to make som ASCII-tables in Arexx, but I can't find any
- : function similar to printf() C. Any advice?
-
- : It maybe look like this:
-
- : 1 One 540 230 0.08
- : 2 Two -1942 2621
- : 3 Three 80 210 0.00
- : 4 Four 13522 1522 0.06
-
- Field-width specifications can be done easily by using the right()
- function. right() will append on additional spaces if you specifiy more
- length than the string put into it, and specify that the string should be
- padded with spaces.
-
- Examples:
-
- do row=1 to 4
- say right(num,3,' ')||right(Jan.row,20,' ')||right(Feb.row,20,' '),
- right(Percent.row,20,' ')
- end
-
- Would do something similiar to what you are trying to display.
-
-